package com.card.game.playback;

import java.util.List;

import com.card.game.Card;
import com.card.game.Player;
import com.card.game.ddz.DdzPlayer;
import com.card.game.pdk.PdkPlayer;
import com.google.common.collect.Lists;

/**   
 * @Description: TODO(用一句话描述该文件做什么) 
 * @author siyunlong  
 * @date 2016年9月5日 下午1:41:15 
 * @version V1.0   
 */
public class Role {
	String userId;
	String img;
	int sex;
	String nickName;
	int tableIndex;
	List<Card> hand;
	
	public Role(Player player) {
		this.userId = player.getUserId();
		this.img = player.img;
		this.nickName = player.nickName;
		this.sex = player.sex;
		this.tableIndex = player.getTableIndex();
		this.hand = Lists.newArrayList(player.getHand().cards);
	}
	
	public Role(DdzPlayer player) {
		this.userId = player.getUserId();
		this.img = player.img;
		this.nickName = player.nickName;
		this.sex = player.sex;
		this.tableIndex = player.getTableIndex();
		this.hand = Lists.newArrayList(player.cards);
	}
	
	public Role(PdkPlayer player) {
		this.userId = player.getUserId();
		this.img = player.img;
		this.nickName = player.nickName;
		this.sex = player.sex;
		this.tableIndex = player.getTableIndex();
		this.hand = Lists.newArrayList(player.cards);
	}
}
